﻿Public Class ProjectActivity
    Implements IObject

    Private id As Integer
    Private estimatedFromDate As Date
    Private estimatedToDate As Date
    Private realFromDate As Date
    Private realToDate As Date
    Private activity As Activity
    Private project As Project

    Public Sub New(ByVal id As Integer)
        Me.id = id
    End Sub

    Public Sub New()
    End Sub

    Public Sub New(ByVal project As Project)
        Me.project = project
    End Sub

    Public Sub New(ByVal id As Integer, ByVal estimatedFromDate As Date, ByVal estimatedToDate As Date, ByVal realFromDate As Date, ByVal realToDate As Date, ByVal activity As Activity, ByVal project As Project)
        Me.id = id
        Me.estimatedFromDate = estimatedFromDate
        Me.estimatedToDate = estimatedToDate
        Me.realFromDate = realFromDate
        Me.realToDate = realToDate
        Me.activity = activity
        Me.project = project
    End Sub

    Public Property idProperty() As Integer
        Get
            Return Me.id
        End Get
        Set(ByVal value As Integer)
            Me.id = value
        End Set
    End Property

    Public Property estimatedFromDateProperty() As Date
        Get
            Return Me.estimatedFromDate
        End Get
        Set(ByVal value As Date)
            Me.estimatedFromDate = value
        End Set
    End Property

    Public Property estimatedToDateProperty() As Date
        Get
            Return Me.estimatedToDate
        End Get
        Set(ByVal value As Date)
            Me.estimatedToDate = value
        End Set
    End Property

    Public Property realFromDateProperty() As Date
        Get
            Return Me.realFromDate
        End Get
        Set(ByVal value As Date)
            Me.realFromDate = value
        End Set
    End Property

    Public Property realToDateProperty() As Date
        Get
            Return Me.realToDate
        End Get
        Set(ByVal value As Date)
            Me.realToDate = value
        End Set
    End Property

    Public Property activityProperty() As Activity
        Get
            Return Me.activity
        End Get
        Set(ByVal value As Activity)
            Me.activity = value
        End Set
    End Property

    Public Property projectProperty() As Project
        Get
            Return Me.project
        End Get
        Set(ByVal value As Project)
            Me.project = value
        End Set
    End Property

    Public Function getId() As Integer Implements IObject.getId
        Return id
    End Function

    Public Function getTableName() As String Implements IObject.getTableName
        Return "PROJECT_ACTIVITIES"
    End Function
End Class
